﻿@model Fcom.VNInsurance.Web.Models.CPInfo
@{
    ViewBag.Title = Model.ProductName;
    var LangCat = (Fcom.VNInsurance.Web.Models.ProductCatLang)ViewBag.LangCat;
    Layout = "~/Views/Shared/_0311layout.cshtml";
    var productFAQ = (IEnumerable<Fcom.VNInsurance.Web.Models.ProductFAQ>)ViewBag.productFAQ;
    var benefitslist = (IEnumerable<Fcom.VNInsurance.Web.Models.BenefitFare>)ViewBag.benefits;
    long fare = 0;
    var Userinfo = (Fcom.IDLib.SaveMoneyID.FullUserInfo)ViewBag.Userinfo;
    var policy =(Fcom.VNInsurance.Web.Models.Policy) ViewBag.policy ;
    var policymoto = (Fcom.VNInsurance.Web.Models.PolicyMotobiker)ViewBag.policymotobiker;
    var policyshiping = (Fcom.VNInsurance.Web.Models.PolicyShipping)ViewBag.policyshiping;
    var motobike = (Fcom.VNInsurance.Web.Models.Motobike)ViewBag.motobike;
}

<div class="container">
     <ul class="breadcrumb" style="margin-bottom:0px !important">
                      <li><a href="@Url.Action("Index", "Home")">@Fcom.VNInsurance.Web.LangResource.Layout.lblHome</a></li>
                      <li><a href="#">@LangCat.DisplayName</a></li>
                      <li class="active">@Model.ProductName</li>
      </ul>
            <div style="clear:both"></div>
    <div class="top_slider container" id="afocus">
             <div class="col-lg-7" style="padding-top:10px;font-weight:bold;">
             @Fcom.VNInsurance.Web.LangResource.ContactLayout.lblComapreMaket
             </div>
			<div class="col-lg-4">
                        <ol class="top_bar">
                        <li><a class="active" id="show_div" href="#"><span>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblinfomation</span></a> </li>
                        <li><a class="bar_2_active" href="#"><span>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblcomparison</span></a></li>
                        <li><a class="bar_3_active" href="#"><span >@Fcom.VNInsurance.Web.LangResource.Layout.lblPolicy</span></a></li>
                        <li style="width: 70px !important;"><a class="bar_4_active"><span style="font-weight:bold;">@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblfinish</span></a></li>
                    </ol>
            <div style="clear:both"></div>
			</div>
           <div style="clear:both"></div>
        </div>
</div>
<div class="container" style="width:800px;margin-left:80px;">
    <h4 style="text-transform:uppercase">I. @Fcom.VNInsurance.Web.LangResource.ContactLayout.lblthepolicyholder</h4>
    <table class="table product-table" id="tbinfocus">
        <tr>
            <td style="width:300px">@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblpolicynumbers : @policy.PolicyID</td><td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lbldate: @policy.PolicyDate.ToString("dd/MM/yyyy") </td>
            
        </tr>
        <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblpolicyholder : @Userinfo.Fullname</td><td></td>
        </tr>
          <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblPhone : @Userinfo.Phone</td><td>Email: @Userinfo.Email</td>
        </tr>
          <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblAddress : @Userinfo.Address</td><td></td>
        </tr>
    </table>
     <h4 style="text-transform:uppercase">II. @Fcom.VNInsurance.Web.LangResource.ContactLayout.lblMotoInsInfo</h4>
    <table class="table product-table" id="tbinfomoto">
     
        <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblpolicyholder : @policymoto.OwnerFullname</td><td></td>
        </tr>
          <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblAddress : @policymoto.Address</td><td></td>
        </tr>
          <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblMotoModel : @motobike.Name</td><td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblregisternumber : @policymoto.ItemIdentityCode</td>
        </tr>
         <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblChassic : @policymoto.BaseModelCode</td><td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblenginenumer : @policymoto.MachineCode</td>
        </tr>
        <tr>
            <td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblperiod : 1 @Fcom.VNInsurance.Web.LangResource.ContactLayout.lblexpirodyear</td><td>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblfrommoto : @policymoto.BeginDate.ToString("dd/MM/yyyy")</td>
        </tr>
        <tr>
            <td><img style="width:130px;height:80px" alt="@Model.ProductName" src="@Url.Content("~/Content/images/CompanyLogo/" + Model.CompanyLogo)" title="@Model.ProductName"/></td>
            <td><b>@Model.CompanyName</b><br />
                @Model.ProductName</td>
        </tr>
    </table>
    <h4 style="text-transform:uppercase">III. @Fcom.VNInsurance.Web.LangResource.ContactLayout.lblbenefitdisplay</h4>
     <table class="table product-table" id="tbinfobenefit">
     
        <thead>
                         <tr>
                             <th>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblbenefitdisplay</th><th>@Fcom.VNInsurance.Web.LangResource.ContactLayout.lblmotofare</th>
                         </tr>
                     </thead>
                     <tbody>
                         @foreach (var li in benefitslist)
                         {
                              <tr><td>
                                    @li.BenefitName
                                 </td>
                             @if (li.isMotoCC)
                             {
                                 if (motobike.CC > 50)
                                 {
                                     fare += li.MotoUp;
                                      <td align="center">
                                    @String.Format("{0:#,###}", li.MotoUp)
                                 </td>
                                 }
                                 else
                                 {
                                     fare += li.MotoDown;
                                         <td align="center">
                                    @String.Format("{0:#,###}", li.MotoDown)
                                 </td>
                                 }
                             }
                             else
                             {
                                 fare += li.Fare;
                                    <td align="center">
                                    @String.Format("{0:#,###}", li.Fare)
                                 </td>
                             }
                             </tr>
                         }
                     </tbody>
                    
    </table>
     <div id="InsuanceFare1">
         <table class="table" id="tbinfopayment">
             <tr>
                 <td style="text-transform:uppercase">@Fcom.VNInsurance.Web.LangResource.ContactLayout.lbltotalpremium</td><td style="font-weight:bold"><span class="phi">@String.Format("{0:#,###}", fare)</span> VND</td>
             </tr>
              <tr>
                 <td style="text-transform:uppercase">VAT():</td><td style="font-weight:bold">0</td>
             </tr>
              <tr>
                 <td style="text-transform:uppercase">TỔNG SỐ TIỀN THANH TOÁN</td><td style="font-weight:bold"><span class="phi">@String.Format("{0:#,###}", fare)</span> VND</td>
             </tr>
         </table>
     </div>
    <div style="clear:both"></div>
    
</div>